package com.stylefeng.guns.modular.poemspoetry.model;

import java.io.Serializable;

import com.baomidou.mybatisplus.enums.IdType;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.annotations.TableName;

/**
 * <p>
 * 宋词表
 * </p>
 *
 * @author stylefeng123
 * @since 2018-03-20
 */
@TableName("poetry")
public class Poetry extends Model<Poetry> {

    private static final long serialVersionUID = 1L;

    /**
     * ID
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;
    /**
     * 标题
     */
    private String title;
    /**
     * 押韵规则
     */
    @TableField("yunlv_rule")
    private String yunlvRule;
    /**
     * 作者ID
     */
    @TableField("author_id")
    private Integer authorId;
    /**
     * 内容
     */
    private String content;
    /**
     * 诗所属朝代（S-宋代, T-唐代）
     */
    private String dynasty;
    /**
     * 作者
     */
    private String author;


    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    public String getYunlvRule() {
        return yunlvRule;
    }

    public void setYunlvRule(String yunlvRule) {
        this.yunlvRule = yunlvRule;
    }

    public Integer getAuthorId() {
        return authorId;
    }

    public void setAuthorId(Integer authorId) {
        this.authorId = authorId;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public String getDynasty() {
        return dynasty;
    }

    public void setDynasty(String dynasty) {
        this.dynasty = dynasty;
    }

    public String getAuthor() {
        return author;
    }

    public void setAuthor(String author) {
        this.author = author;
    }

    @Override
    protected Serializable pkVal() {
        return this.id;
    }

    @Override
    public String toString() {
        return "Poetry{" +
        "id=" + id +
        ", title=" + title +
        ", yunlvRule=" + yunlvRule +
        ", authorId=" + authorId +
        ", content=" + content +
        ", dynasty=" + dynasty +
        ", author=" + author +
        "}";
    }
}
